<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ include file="/include/taglibs.jsp" %>
<html>
<head>
    <%@include file="/include/header.html"%>
    <script src="${ctx}/appjs/tenant/role/role.js"></script>
</head>

<script type="text/javascript">
    $('#topLink', window.parent.document).html(function(i,origText){
		return '<ol class="breadcrumb">' +
				'<li class="breadcrumb-item">' +
				'<a href="">主页</a>' +
				'</li>' +
				'<li class="breadcrumb-item">' +
				'<a>平台设置</a>' +
				'</li>' +
				'<li class="breadcrumb-item">' +
				'<a>平台角色设置</a>' +
				'</li>' +
				'<li class="breadcrumb-item">' +
				'<strong>编辑平台角色</strong>' +
				'</li>' +
				'<li class="breadcrumb-item">' +
				'<a href="javascript:window.history.back()"><i class="fa fa-times"></i> 返回</a>' +
				'</li>' +
				'</ol>';
    });
</script>

<body class="gray-bg">
<div class="wrapper wrapper-content animated fadeInRight">
	<div class="row">
		<div class="col-sm-12">
			<div class="ibox">
				<div class="ibox-title">
					<h5><strong>编辑资料</strong></h5>
					<div class="ibox-tools">
						<a class="close-link">
							<i class="fa fa-times"></i>
						</a>
					</div>
				</div>
				<div class="ibox-content">
					<form id="frmEdit">
						<input id="tenantRoleId" name="tenantRoleId" type="hidden" value="${role.tenantRoleId}">
						<input id="menuIds"	name="menuIds" type="hidden">

						<div class="form-group row">
							<label for="roleName" class="col-sm-2 col-form-label text-right">角色名称：</label>
							<div class="col-sm-8">
								<input id="roleName" name="roleName" class="form-control"
									   type="text" value="${role.roleName}">
							</div>
						</div>
						<div class="form-group row">
							<label for="remarks" class="col-sm-2 col-form-label text-right">说明：</label>
							<div class="col-sm-8">
								<input id="remarks" name="remarks" class="form-control"
									   type="text" value="${role.remarks}">
							</div>
						</div>
						<div class="form-group row">
							<label for="menuTree" class="col-sm-2 col-form-label text-right">菜单权限：</label>
							<div class="col-sm-8">
								<div id="menuTree"></div>
							</div>
						</div>

						<div class="form-group">
							<div class="col-sm-3 col-sm-offset-8 text-right">
								<button type="submit" class="btn btn-success">提交</button>
							</div>
						</div>
					</form>
				</div>
			</div>
		</div>
	</div>
</div>
<script type="text/javascript">
	editRole.init();
</script>
</body>

</html>
